package com.yao.service.impl;

import com.yao.dao.ArticleDao;
import com.yao.entity.Article;
import com.yao.service.ArticleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class ArticleServiceImpl implements ArticleService {

    //获取ArticleDao对象
    @Autowired
    private ArticleDao articleDao;

    /**
     * 添加文章信息
     * @param article
     */
    public void saveArticle(Article article) {

        articleDao.saveArticle(article);

//        int i = 1 / 0;
    }
}
